//
//  UIView+Frame.m
//  网易彩票
//
//  Created by 徐攀 on 16/3/27.
//  Copyright © 2016年 徐攀. All rights reserved.
//

#import "UIView+Frame.h"

@implementation UIView (Frame)

- (CGFloat)origin_x {
    return self.frame.origin.x;
}

- (void)setOrigin_x:(CGFloat)origin_x {
    CGRect frame = self.frame;
    frame.origin.x = origin_x;
    self.frame = frame;
}

- (CGFloat)origin_y {
    return self.frame.origin.y;
}

- (void)setOrigin_y:(CGFloat)origin_y {
    CGRect frame = self.frame;
    frame.origin.y = origin_y;
    self.frame = frame;
}

- (CGFloat)size_w {
    return self.frame.size.width;
}

- (void)setSize_w:(CGFloat)size_w {
    CGRect frame = self.frame;
    frame.size.width = size_w;
    self.frame = frame;
}

- (CGFloat)size_h {
    return self.frame.size.height;
}

- (void)setSize_h:(CGFloat)size_h {
    CGRect frame = self.frame;
    frame.size.height = size_h;
    self.frame = frame;
}
@end
